/*
 * @Author: 王雁鹏
 * @Date: 2022-12-29 21:51:41
 * @LastEditTime: 2023-04-01 16:56:25
 * @LastEditors: Please set LastEditors
 * @Description: 
 * @FilePath: \assistf:\web-vue\express\routes\area.js
 * -------------------------------------
 */
var express = require('express');
var router = express.Router();
const db = require("../mysql/index.js");

db.query((rows) => {
    router.get('/', function (req, res, next) {
        res.send({ data: rows });
    });
    router.get('/name', function (req, res, next) {
        res.send({ data: rows });
    });
})
/* GET home page. */
// router.get('/', function (req, res, next) {
//     res.send({ data: res });
// });

module.exports = router;
